import javax.swing.*;
import java.awt.*;

public class XButton extends JButton {

    public XButton(String text, Icon icon) {
        super(text, icon);
        setBorder(BorderFactory.createEmptyBorder());
        setMargin(new Insets(0,5,0,5));
        setForeground(Color.blue);
        setIconTextGap(4);
    }
}
